public class GirlFriend {

    private String name;
    private int age;
    private String gender;

    public void setName(String name){
        this.name = name;
    }
    public String getName(){
        return name;
    }
    public void setAge(int age){
        if(age<=18&&age>=0){
            this.age = age;
        }
    }
    public int getAge(){
        return age;
    }
    public void setGender(String s){
        this.gender = gender;

    }
    public String getGender(){
        return gender;
    }
    public void sleep() {
        System.out.println(this.name + "正在睡觉");
    }

    public void eat() {
        System.out.println(this.name + "正在吃饭");
    }

}
